package com.xxxx.server.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.xxxx.server.mapper.SalaryMapper;
import com.xxxx.server.pojo.RespPageBean;
import com.xxxx.server.pojo.Salary;
import com.xxxx.server.pojo.pojo01.SalarySobCfg;
import com.xxxx.server.service.ISalaryService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

import java.util.HashMap;
import java.util.Map;

/**
 * <p>
 * 服务实现类
 * </p>
 *
 * @author zhoubin
 */
@Service
public class SalaryServiceImpl extends ServiceImpl<SalaryMapper, Salary> implements ISalaryService {
    @Autowired
    private SalaryMapper salaryMapper;

    @Override
    public Map<String, Object> selectList(RespPageBean respPageBean) {
        PageHelper.startPage(respPageBean.getCurrentPage(), respPageBean.getSize());

        List<SalarySobCfg> list = salaryMapper.salarySobCfgList();

        PageInfo<SalarySobCfg> pageInfo = new PageInfo<>(list);

        Map<String, Object> map = new HashMap<>();
        map.put("data", list);
        map.put("total", pageInfo.getTotal());

        return map;
    }

    @Override
    public boolean updateById01(RespPageBean id) {



        return false;
    }


}




